﻿<%@ WebHandler Language="C#" Class="LoginHandler" %>

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using Cisoft.IntegrationSystem.Common;

public class LoginHandler : IHttpHandler {
    
    public void ProcessRequest (HttpContext context) {
        context.Response.ContentType = "text/plain";
        if (context.Session["CheckCode"] != null && context.Session["CheckCode"].ToString() != "")
        {
            string _tmpCheckCode = context.Session["CheckCode"].ToString();
            if (_tmpCheckCode.ToLower() == context.Request["code"].ToString().Trim().ToLower())
            {
                
            }
            else
            {
                context.Response.Write("验证码错误");
                return;
            }
        }
        else {
            context.Response.Write("验证码过期");
            return;
        }
    }
 
    public bool IsReusable {
        get {
            return false;
        }
    }

}